\chapter{Workspaces and Window Management}

\section{Window Management and Docking}

All dialog boxes, waveform groups, and other GUI elements in ngscopeclient may be used docked or free-floating as
needed.

To dock a window, drag the title bar (if floating) or tab title (if docked) to the desired location (Fig.
\ref{w-docking}).

\begin{figure}[h]
\centering
\bigimage{ng-images/docking.png}
\caption{Docking a floating window}
\label{w-docking}
\end{figure}

On MacOS, Linux X11, and Windows you can drag dialogs or waveform areas out of the main ngscopeclient window to create
multiple top-level windows. This can be useful for complex experimental setups or on multi-monitor workstations.

NOTE: Multi-window mode is not currently available on Linux Wayland due to
\href{https://github.com/ocornut/imgui/issues/8609}{GUI toolkit limitations} however we hope to support this in the
future.

\section{Workspaces}

To create more complex windowing layouts, you may find it helpful to create \emph{workspaces}.

A workspace is a window which has no function of its own, and simply serves as a container for docking other windows
into. The workspace can itself be docked into another workspace or the main application window, allowing creation of
complex multi-window or multi-tab layouts to suit your experimental needs (Fig. \ref{w-workspace}, \ref{w-workspace2},
\ref{w-workspace3}).

In the default ngscopeclient window layout, for example, the "Filter Graph" tab is a workspace which contains both the
filter graph editor and the filter palette.

To rename a workspace, right click on the window title (if floating) or tab title (if docked) and enter the desired
name.

\begin{figure}[h]
\centering
\bigimage{ng-images/workspace.png}
\caption{A docked workspace containing a waveform group and two protocol analyzer tabs}
\label{w-workspace}
\end{figure}

\begin{figure}[h]
\centering
\bigimage{ng-images/workspace2.png}
\caption{Switching from the waveform workspace to the filter graph editor workspace}
\label{w-workspace2}
\end{figure}

\begin{figure}[h]
\centering
\bigimage{ng-images/workspace3.png}
\caption{Free-floating workspace not docked to the main application window}
\label{w-workspace3}
\end{figure}
